# _*_ coding: utf-8 _*_
__author__ = 'yinlei'
__date__ = '2018-05-21 12:29'

import memcache

cache = memcache.Client(['127.0.0.1:11211'],debug=True)
def set(key,value,timeout=600):
    return cache.set(key,value,time=timeout)

def get(key,default=None):
    return cache.get(key) or default

def delete(key):
    return cache.delete(key)